﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Ajaxna.Designers;
using System.Drawing.Design;

namespace Ajaxna
{
    [ParseChildren(true),
    Designer(typeof(CustomTypeUIExampleDesigner))]
    [ToolboxData("<{0}:CustomTypeUIExample runat=server></{0}:CustomTypeUIExample>")]
    public class CustomTypeUIExample : CompositeControl
    {
        string _textValue;

        [Category("Configuration"),
        Description("Some text value goes here"),
        Editor(typeof(TextEditor), typeof(UITypeEditor))]
        public string TextValue
        {
            get { return _textValue; }
            set 
            { 
                _textValue = value;                 
            }
        }

        List<AjaxnaScriptReference> _scripts = new List<AjaxnaScriptReference>();
        [PersistenceMode(PersistenceMode.InnerProperty),
        Editor(typeof(CustomCollectionEditor), typeof(UITypeEditor))]
        public List<AjaxnaScriptReference> Scripts
        {
            get { return _scripts; }            
        }

    }
}
